package com.springinaction.ch04.noargsxml;

import org.junit.Test;
import org.junit.runner.RunWith;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.config.ConfigurableBeanFactory;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.Scope;
import org.springframework.context.annotation.ScopedProxyMode;
import org.springframework.test.context.ContextConfiguration;
import org.springframework.test.context.junit4.SpringJUnit4ClassRunner;
import org.springframework.web.context.WebApplicationContext;

import static org.junit.Assert.assertNotNull;

@RunWith(SpringJUnit4ClassRunner.class)
@ContextConfiguration("classpath:com/springinaction/ch04/noargsxml/aopstudy.xml")
public class AudienceConfigTest {

    @Autowired
    private Performance performance;
    @Autowired
    private Audience audience;

    @Test
    public void aopTest(){
        assertNotNull(performance);
        performance.perform();
    }

}
